package com.liyiqing.secondhandmall.memberservice.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.liyiqing.commonservice.utils.PageUtils;
import com.liyiqing.commonservice.utils.R;
import com.liyiqing.commonservice.vo.MemberCollectSpuVo;
import com.liyiqing.secondhandmall.memberservice.entity.MemberUserCollectSpuEntity;

import java.util.Map;

/**
 * 某账号收藏的商品
 *
 * @author LiYiQing
 * @email 1570865668@qq.com
 * @date 2022-02-18 22:47:22
 */
public interface MemberUserCollectSpuService extends IService<MemberUserCollectSpuEntity> {

    PageUtils queryPage(Map<String, Object> params);


    MemberUserCollectSpuEntity selectRecordByMidAndSid(Long memberId, Long spuId);


    R selectRecordByMemberId(Long memberId);


    /**
     * 工具：
     * 根据数据库的一条数据，借助远程服务productFeignService，
     * 创建一个展示给前端的MemberCollectSpuVo对象
     */
    MemberCollectSpuVo createMemberCollectSpuVo(MemberUserCollectSpuEntity userCollect);
}

